//
//  UPRepaymentCarouselView.h
//  Uang Pasti
//
//  Created by 李永彬 on 2025/8/24.
//

#import <UIKit/UIKit.h>
#import "LeaderibleModel.h"

@class UPGoToApplyCarouselView;

NS_ASSUME_NONNULL_BEGIN

@protocol UPGoToApplyCarouselViewDelegate <NSObject>
- (void)carouselView:(UPGoToApplyCarouselView *)carouselView didSelectItemAtIndex:(NSInteger)index data:(StultiiveModel *)data;
- (void)carouselView:(UPGoToApplyCarouselView *)carouselView didScrollToIndex:(NSInteger)index data:(StultiiveModel *)data;
@end

@interface UPGoToApplyCarouselView : UIView

@property (nonatomic, weak) id<UPGoToApplyCarouselViewDelegate> delegate;
@property (nonatomic, strong, readonly) NSArray<StultiiveModel *> *dataSources;

- (void)updateWithDatas:(NSArray<StultiiveModel *> *)datas;
- (void)setDatas:(NSArray<StultiiveModel *> *)datas;
- (void)scrollToIndex: (NSInteger) nextIndex;

@end

NS_ASSUME_NONNULL_END
